export interface PageInfo<T> {
    total: number;
    list: Array<T>
    pageNum: number
    pageSize: number
    size: number
    startRow: number
    endRow: number
    pages: number
    prePage: number
    nextPage: number
    isFirstPage: number
    isLastPage: number
    hasPreviousPage: boolean
    hasNextPage: boolean
}

export interface IRootState {
    dict: SystemDictEntity[],
    user: UserEntity,
    permissions: any
}

export interface ProjectEntity {
    createTime?: Date
    updateTime?: Date
    id?: Number
    projectName?: String
    projectCode?: String
    projectTime?: String
    projectPeriod?: String
    projectLevel?: String
    projectObjectName?: String
    projectSpeciesName?: String
    projectTarget?: String
    projectStatus?: String
    createUserId?: number
    ownerUserId?: number
    createUserName?: String
    ownerUserName?: String
    geneEditType?: String
    species?: String,
}

export interface SystemDictEntity {
    id: number
    dictName: string;
    dictType: string;
    dictStatus: string
    dictValueName: string
    dictValueCode: string
    systemCode: string
}

export interface UserEntity {
    token: string
    userId?: number
    userName: string
    roleName: string
    roleId?: number
    permissions: []
}

export interface TokenEntity {
    token: string
    time: number
}

export interface Task {
    id: number
    userId: number
    heat: number
    cUrl: string;
    claimStatus: string
    rewardAmount: string
    updatedTime: Date
    createdTime: Date
}

export interface TranslatedTask {
    id: number;                // 任务ID
    taskId: number;            // 任务编号
    cUrl: string;              // 任务链接
    claimUserId: number;       // 认领用户ID
    rustUrl: string;           // Rust 地址库
    readmeDetail: string;      // 任务说明
    likes: number;             // 点赞数
    diss: number;              // 踩数
    updatedTime: string | null; // 更新时间
    createdTime: string;       // 创建时间
}

export interface TaskClaimed {
    id: number;             // 任务认领的 ID
    taskId: number;         // 任务的 ID
    claimUserId: number;    // 认领用户的 ID
    rustUrl: string;        // Rust 地址库
    readmeDetail: string;   // 任务说明
    progress: string;       // 任务进度
    createdTime: string;    // 创建时间
    updatedTime: string | null; // 更新时间，可能为 null
}

export interface TaskCount {
    unclaimedCount: number
    completedCount: number
}

export interface responseList<T> {
    meta: {
        code: number;
        msg: string;
    };
    data: T[];
}

export interface responseObject<T> {
    meta: {
        code: number;
        msg: string;
    };
    data: T;
}


